<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>    
<%@ taglib prefix="display" uri="http://displaytag.sf.net" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt" %>  
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>  
<!--pub_lista_feedback_pending.jsp--> 

    <!-- content -->		
			<div id="content" align="center">
				<h2> Gestione Feedback in Attesa </h2>
				<br />


					<c:if test="${ !empty pendingIn }" >
					<strong>Sei in attesa di ricevere <c:out value="${fn:length(pendingIn)}" /> feedback </strong><br />
					<table  border="1" >
					  <thead>
					    <tr>
					      <th>Servizio</th>
					      <th>Utente</th>
					      <th>Oper</th>
					    </tr>
					  </thead>
					  <tfoot>
					  <tr>
					      <td colspan="2"><strong>Tot</strong></td>
					      <td><strong><c:out value="${fn:length(pendingIn)}" /></strong></td>
					 </tr>
					 </tfoot>
					 <tbody>
						 <c:forEach var="fIn" items="${pendingIn}" >
							 <tr>
								 <td><a href="dettaglioServizio.html?idServ=<c:out value="${fIn.idServ}"/>&caller=listaFeedbackPending.html"> <c:out value="${fIn.idServ}"/> </a></td>
								 <td><a href="profiloUtente.html?idUser=<c:out value="${fIn.idUserInse}"/>"> <c:out value="${fIn.nomeUserInse}"/> </a></td>
								 <td><a href="sollecitaFeedback.html?idFeed=<c:out value="${fIn.idFeed}"/>&caller=listaFeedbackPending.html"> <img src="<%=request.getContextPath()%>/images/level_write.gif" alt="SOLLECITA FEEDBACK"/> </a></td>
							 </tr>
						  </c:forEach>
					 </tbody>
					 </table>	
					 </c:if>		
			
			<br />
			<br />
			
					<c:if test="${ !empty pendingOut }" >
					<strong>Hai <c:out value="${fn:length(pendingOut)}" /> feedback da rilasciare</strong><br />
					<table  border="1">
					  <thead>
					    <tr>
					      <th>Servizio</th>
					      <th>Utente</th>
					      <th>Oper</th>
					      
					    </tr>
					  </thead>
					  <tfoot>
					  <tr>
					      <td colspan="2"><strong>Tot</strong></td>
					      <td><strong><c:out value="${fn:length(pendingOut)}" /></strong></td>
					 </tr>
					 </tfoot>
					 <tbody>
						 <c:forEach var="fout" items="${pendingOut}" >
							 <tr>
								 <td><a href="dettaglioServizio.html?idServ=<c:out value="${fout.idServ}"/>&caller=listaFeedbackPending.html"> <c:out value="${fout.idServ}"/> </a></td>
								 <td><a href="profiloUtente.html?idUser=<c:out value="${fout.idUserInse}"/>"> <c:out value="${fout.nomeUserInse}"/> </a></td>
								 <td><a href="dettaglioFeedback.html?idFeed=<c:out value="${fout.idFeed}"/>&caller=listaFeedbackPending.html"> <img src="<%=request.getContextPath()%>/images/level_write.gif" alt="INSERISCI FEEDBACK"/> </a></td>
							 </tr>
						  </c:forEach>
					 </tbody>
					 </table>	
					 </c:if>		
			
			
			
			
			
			
				<br /><br /><br /><br /><br /><br />
				<br /><br /><br /><br /><br /><br />
			</div>
			<div id="aside">
				<h3>
					Suggerimenti
				</h3>
				<p>
					La prima lista rappresenta i feedback che ti devono essere rilasciati da altri utenti per un servizio assegnato		
				</p>
				<p>
					La seconda lista invece elenca tutti i feedback che ancora non hai rilasciato
				</p>
			</div>
			